package per.ethan.cloud.common.exception;

import lombok.Data;
import lombok.EqualsAndHashCode;
import per.ethan.cloud.common.domain.ErrorCodeVO;

/**
 * @author Ethan
 * @date 2020/03/11 12:36
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class ServiceException extends RuntimeException {

    private ErrorCodeVO errorCodeVO;

    public ServiceException(ErrorCodeVO errorCodeVO) {
        super(errorCodeVO.getMessage());
        this.errorCodeVO = errorCodeVO;
    }

}
